apiVersion: batch/v1
kind: Job
metadata:
  name: migration
  namespace: {{ .Values.namespace }}
spec:
  template:
    metadata:
      labels:
        app: migration
    spec:
      restartPolicy: OnFailure
      containers:
        - args:
            - 'migrate'
            - 'apply'
            - '--url'
            - 'postgres://chroma:chroma@postgres:5432/chroma?sslmode=disable'
          image: migration
          imagePullPolicy: IfNotPresent
          name: migration
---
